import 'package:bxultimate/resources/assets.dart';
import 'package:flutter/material.dart';
import 'package:get/get.dart';

class MkPage extends StatefulWidget {
  final String? bg;

  const MkPage({super.key, required this.child, this.bg});

  final Widget child;

  @override
  State<MkPage> createState() => _BdPageState();
}

class _BdPageState extends State<MkPage> {
  @override
  Widget build(BuildContext context) {
    return Container(
      decoration: BoxDecoration(
          color: Get.theme.scaffoldBackgroundColor,
          image: DecorationImage(
              image: AssetImage(widget.bg ?? Assets.commonTopBg),
              fit: BoxFit.fitWidth,
              alignment: Alignment.topCenter)),
      child: widget.child,
    );
  }
}
